package com.foreknow.mapping;

import com.foreknow.model.business;

import java.sql.ResultSet;
import java.sql.SQLException;

public class BusinessMapping implements EntityMapping {

    @Override
    public Object mapping(ResultSet rs) throws SQLException {
         business b=new business();
         b.setBusinessId(rs.getInt("businessId"));
         b.setBusinessAddress(rs.getString("businessAddress"));
         b.setBusinessExplain(rs.getString("businessExplain"));
         b.setBusinessName(rs.getString("businessName"));
         b.setPassword(rs.getString("password"));
         b.setDeliveryPrice(rs.getFloat("deliveryPrice"));
         b.setStarPrice(rs.getFloat("starPrice"));

        return b;
    }
}
